package com.xxg.renrencommon.domain.bean;

import lombok.Data;
import org.springframework.data.mongodb.core.mapping.Document;

import java.util.Date;
import java.util.Map;

/**
 * 商品采集信息
 *
 * @author szj
 * @date 2021/11/29
 */
@Data
@Document(collection = "productGatherInfo")
public class ProductGatherInfo implements NewGoodsId{
    /**
     * 数据主键
     */
    private String id;

    /**
     * 创建时间
     */
    private Date createTime;

    /**
     * 记录更新时间
     */
    private Date updateTime;

    /**
     * 商品spuId
     */
    private Integer spuId;

    /**
     * 采集完的商品spuId
     */
    private Integer newSpuId;

    /**
     * 商品属于店铺的Id
     */
    private Integer originShopId;

    /**
     * 采集用户Id
     */
    private Integer userId;

    /**
     * 采集店铺Id
     */
    private Integer shopId;

    /**
     * 新旧skuId映射 键新skuId 值旧skuId
     */
    private Map<String, Integer> skuIdMap;

    @Override
    public void setNewGoodsId(Integer newGoodsId) {
        this.newSpuId = newGoodsId;
    }
}
